<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN" "http://www.wapforum.org/DTD/xhtml-mobile10.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
 <head> 
  <meta content="IE=11.0000" http-equiv="X-UA-Compatible" /> 
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
  <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" /> 
  <meta name="format-detection" content="telephone=no" /> 
  <meta name="apple-mobile-web-app-capable" content="yes" /> 
  <meta http-equiv="pragma" content="no-cache" /> 
  <meta http-equiv="cache-control" content="no-cache" /> 
  <meta http-equiv="expires" content="0" /> 
  <title></title> 
  <meta name="keywords" content="境外就业网,出国劳务,出国打工,新加坡劳务,新加坡打工,辽宁境外就业网,劳务输出公司,出国劳务中介,辽宁打工,劳务合同,新加坡出国指南,沈阳劳动力,人才,澳大利亚劳务,美国工作,加拿大务工,辽宁劳务信息,江苏劳务外派,上海输出劳务,北京国际劳务,研修生,工作准证,出国签证,护士出国,厨师出国,国外工作,护照,jwjy,chuguo,work abroad,job,job361,361job" /> 
  <meta name="description" content="境外就业网,出国劳务共享平台，国际人生规划专家。国家商务部许可资质，12年外派劳务经验。境外就业网包括职位发布、签证解析、出国常识、面试培训等功能，提供境外就业、出国劳务、出国打工一站式专业服务。境外就业网,出国工作通！" /> 
  <meta name="GENERATOR" content="MSHTML 11.00.9600.17280" /> 
  <link rel="stylesheet" href="../css/public-v6.css" />
  <link rel="stylesheet" href="../css/mlogin.css" />
  <link rel="stylesheet" href="../css/footer.css" />
  <link rel="stylesheet" href="../css/com.css" />
  <script type="text/javascript" src="../../js/jquery-1.8.3.min.js" ></script>
  <script type="text/javascript">
	//因为外部js(如default1.5.js)中无法直接获取EL表达式的值，所以这里在本页面的js中设置了一个全局变量保存EL表达式的值，再在外部js中直接使用这个全局变量即可。webPathEntercn是在后台获取的webDomain+webPort+webName(网站域名+端口号+工程名)字符串。
	var webPathEntercn = "";
	var companyId = "";
	var jobId = "";
	//刚载入html页面时就执行一次ajax提交
	window.onload = function(){
		jobId = GetQueryString("waJob.id");
		var companyType = GetQueryString("companyType");
		companyId = GetQueryString("companyId");
		var accountId = GetQueryString("accountId");
		webPathEntercn = GetQueryString("webPath");
		
		//修改css图片路径。这样写虽然可以避免将图片路径写死，但是加载到页面中的速度也会变慢。
		$("#icon-arrow1").css({
			"background": "url('../img/bg-arrow-v1111.png') no-repeat",  
			"background-size": "80px auto",
			"background-position-x": "-60px",
			"background-position-y": "-40px"
		})
		
		$.ajax({
			async : false,
			cache : false,
			type : "GET",
			dataType : "jsonp",
			data : {"waJob.id":jobId,
				"companyType":companyType,
				"companyId":companyId,
				"accountId":accountId
			},
			url : webPathEntercn +　"/entercn/enroll/enterMobileEnrollForJobPageAjax.action",
			error : function(XMLHttpRequest, textStatus, errorThrown) {    
				//这几个参数可以打出错误类型
				alert("请求对象XMLHttpRequest: "+XMLHttpRequest);  
		        alert("错误类型textStatus: "+textStatus);  
		        alert("异常对象errorThrown: "+errorThrown);  
			},
			success : function(data) {
				//var result = eval("(" + data + ")");
				var result = data;
				document.getElementById("waEnroll_jobId").value = result.waEnroll_jobId;
				document.getElementById("waEnroll_jobName").value = result.waEnroll_jobName;
				document.getElementById("waEnroll_country").value = result.waEnroll_country;
				document.getElementById("waEnroll_industry").value = result.waEnroll_industry;
				document.getElementById("company_type").value = result.company_type;
				document.getElementById("company_id").value = result.company_id;
				document.getElementById("account_id").value = result.account_id;
				
				//标题带的公司名、电话、qq号
				document.getElementsByTagName("title")[0].innerHTML = "我要报名 -- " +　result.company_name;
				if(result.telephone != undefined && result.telephone != ""){
					var telephoneNum = result.telephone;
					if(telephoneNum.length > 12){
						telephoneNum = telephoneNum.substring(0, 12);
					}
					var telArray = document.getElementsByName("tel-report");
					telArray[0].innerHTML = telephoneNum;
					for(var i = 0; i < telArray.length; i++) { 
						//如果是想写成“telArray[i].onclick = 函数名”的形式，是不能传参的，即只能写成“telArray[i].onclick = addTelaccess”的形式，若直接写成“telArray[i].onclick = addTelaccess(telephoneNum)”，会先去执行那个函数，就不对了。想传参必须用function匿名函数套起来。
						telArray[i].onclick = function(){      
							addTelaccess(telephoneNum); 
						}
						telArray[i].href = "tel:" + telephoneNum;
					} 
				}
				if(result.qqNum != undefined && result.qqNum != ""){
					document.getElementById("qqNum-report").onclick = function(){
						addQqaccess(result.qqNum);
					}
					document.getElementById("qqNum-report").href = "http://wpa.qq.com/msgrd?v=3&uin=" + result.qqNum + "&site=qq&menu=yes";
				}
			}
		});
	}
	
	//通过参数名获取地址栏url中传的值
	function GetQueryString(name){      
	     var reg = new RegExp("(^|&)"+ name +"=([^&]*)(&|$)");      
	     var r = window.location.search.substr(1).match(reg);      
	     if (r!=null) return unescape(r[2]); return null;      
	} 
	
	//提交报名
	function submitForm(){
		//alert($("#registerForm").serialize());
		if(checkForm()){
			$.ajax({
				async : false,
				cache : false,
				type : "GET",
				dataType : "jsonp",
				data : $("#registerForm").serialize(),    //将form表单序列化，即将表单元素的值转化为“a=1&b=2&c=3&d=4”的形式作为参数传过去。如果这里ajax用的是POST提交的话，则form表单中的中文字符提交过去不会出问题，但是因为要用ajax jsonp跨域，所以只能改成GET提交了。
				url : webPathEntercn +　"/entercn/enroll/enterMobileEnrollForJobSaveAjax.action",
				error : function(XMLHttpRequest, textStatus, errorThrown) { 
					//这几个参数可以打出错误类型
					alert("请求对象XMLHttpRequest: "+XMLHttpRequest);  
			        alert("错误类型textStatus: "+textStatus);  
			        alert("异常对象errorThrown: "+errorThrown);  
				},
				success : function(data) {
					var result = data;
					if(result.error != undefined &&　result.error != ""){
						document.getElementById("mobile").style.color = "red";
						document.getElementById("mobile").innerHTML = result.error;
					}else{
						window.location.href = "mobileEnrollForJobSuccess.html?webPath="+webPathEntercn+"&companyId="+companyId+"&waJob.id="+jobId;
					}
				}
			});
		}
	}

	//提交前的验证函数
	function checkForm() {
		var checkFlag = true;
		var focusFlag = true;
		if (!checkNotNullAndSize(document.getElementById('full_name_check'),'full_name',50,'该项目必须填写','该项目长度应在50字以内','')) {
			checkFlag = false;
			if (focusFlag == true) {
				document.getElementById('full_name_check').focus();
				document.getElementById('full_name_check').select();
				focusFlag = false;
			}
		}
		
		if (!checkNotNullAndIsMobile(document.getElementById('mobile_check'),'mobile','手机号格式不正确','该项目必须填写','请输入常用手机号')) {
			checkFlag = false;
			if (focusFlag == true) {
				document.getElementById('mobile_check').focus();
				document.getElementById('mobile_check').select();
				focusFlag = false;
			}
		}
		
		if (!checkIsMobile(document.getElementById('mobile_bak_check'),'mobile_bak','手机号格式不正确','')) {
			checkFlag = false;
			if (focusFlag == true) {
				document.getElementById('mobile_bak_check').focus();
				document.getElementById('mobile_bak_check').select();
				focusFlag = false;
			}
		}
		
		if (!checkSize(document.getElementById('phone_check'),'phone',50,'该项目长度应在50字以内','')) {
			checkFlag = false;
			if (focusFlag == true) {
				document.getElementById('phone_check').focus();
				document.getElementById('phone_check').select();
				focusFlag = false;
			}
		}
		
		if (!checkIsEmail(document.getElementById('email_check'),'email','电子邮件格式不正确','',50,'该项目长度应在50字以内')) {
			checkFlag = false;
			if (focusFlag == true) {
				document.getElementById('email_check').focus();
				document.getElementById('email_check').select();
				focusFlag = false;
			}
		}
		
		if (!checkSize(document.getElementById('qq_num_check'),'qq_num',50,'该项目长度应在50字以内','')) {
			checkFlag = false;
			if (focusFlag == true) {
				document.getElementById('qq_num_check').focus();
				document.getElementById('qq_num_check').select();
				focusFlag = false;
			}
		}
		
		if (!checkSize(document.getElementById('description_check'),'description_t',500,'该项目长度应在500字以内','')) {
			checkFlag = false;
			if (focusFlag == true) {
				document.getElementById('description_check').focus();
				document.getElementById('description_check').select();
				focusFlag = false;
			}
		}

		return checkFlag;
	}
	
	
	//记录点击的QQ
	function addQqaccess(qqNum){
	 	//使用ajax
	 	$.ajax({
			async : true,
			cache : false,
			type : "GET",
			dataType : "jsonp",
			data : {"waQqaccess.qqNum":qqNum},
			url : webPathEntercn + "/cn/qqaccess/addQqaccess.action",
			error : function() {//请求失败处理函数
				//alert("提交失败！");
			},
			success : function(data) { //请求成功后处理函数。
			}
		});
	}
	
	//记录点击的电话
	function addTelaccess(telephone){
	 	//使用ajax
	 	$.ajax({
			async : true,
			cache : false,
			type : "GET",
			dataType : "jsonp",
			data : {"waTelaccess.telephone":telephone},
			url : webPathEntercn + "/cn/telaccess/addTelaccessAgency.action",
			error : function() {//请求失败处理函数
				//alert("提交失败！");
			},
			success : function(data) { //请求成功后处理函数。
			}
		});
	}
</script> 
  <style>
.nav1 {
	background: rgb(253, 80, 4); position: relative; z-index: 999;
}
.nav-back1 {
	padding: 7px 0px 7px 6px; left: 0px; top: 0px; height: 26px; color: rgb(255, 255, 255); overflow: hidden; display: inline-block; position: absolute;
}
.nav-back1:visited {
	color: rgb(255, 255, 254);
}
.nav-back1 span {
	background: #5f7dbe; padding: 5px 5px 5px 2px; line-height: 16px; font-size: 14px; float: left;
}
.nav-back1 .arrow-left1 {
	background-position: -60px -40px; width: 12px; height: 26px; float: left;
}
</style> 
 </head> 
 <body> 
  <form id="registerForm" name="registerForm" onsubmit="return checkForm();" action="" method="post"> 
   <input type="hidden" id="waEnroll_jobId" name="waEnroll.jobId" /> 
   <input type="hidden" id="waEnroll_jobName" name="waEnroll.jobName" /> 
   <input type="hidden" id="waEnroll_country" name="waEnroll.country" /> 
   <input type="hidden" id="waEnroll_industry" name="waEnroll.industry" /> 
   <input type="hidden" id="company_type" name="companyType" /> 
   <input type="hidden" id="company_id" name="companyId" /> 
   <input type="hidden" id="account_id" name="accountId" /> 
   <div id="divregister"> 
    <div class="nav1"> 
     <h2 class="nav-title">我要报名</h2> 
     <a class="nav-back1" href="../index.html"> <i class="icon-arrow1 arrow-left1" id="icon-arrow1"></i> <span id="btnBack1">主页</span> </a> 
     <div style="top: 6px; right: 10px; position: absolute;"> 
     </div> 
    </div> 
    <div class="main" style="min-height: 550px;"> 
     <div class="fn-mt-login fn-mlr" id="toolerror" style="display: none;"> 
      <span class="tip01 tip01-warn" id="ToolTip"></span> 
     </div> 
     <div class="enroll-regist"> 
      <div class="form-text-enroll noc"> 
       <label><span style="color: #ff4400;">*</span> 姓名：</label> 
       <input name="waEnroll.fullName" id="full_name_check" class="form-text" onblur="checkNotNullAndSize(this,'full_name',50,'该项目必须填写','该项目长度应在50字以内','')" placeholder="请输入你的真实姓名" /> 
       <i class="icon icon-clear"></i> 
      </div> 
      <div class="add_users_lib_register"> 
       <font id="full_name" color="#5F5F5F"></font> 
      </div> 
      <div class="form-text-enroll noc"> 
       <label><span style="color: #ff4400;">*</span> 手机号：</label> 
       <input name="waEnroll.mobile" id="mobile_check" class="form-text" onblur="checkNotNullAndIsMobile(this,'mobile','手机号格式不正确','该项目必须填写','请输入常用手机号')" placeholder="请输入常用手机号" /> 
       <i class="icon icon-clear"></i> 
      </div> 
      <div class="add_users_lib_register"> 
       <font id="mobile" color="#5F5F5F"></font> 
      </div> 
      <div class="form-text-enroll noc"> 
       <label>联系人手机：</label> 
       <input name="waEnroll.mobileBak" id="mobile_bak_check" class="form-text" onblur="checkIsMobile(this,'mobile_bak','手机号格式不正确','')" placeholder="请输入紧急联系人手机号" /> 
       <i class="icon icon-clear"></i> 
      </div> 
      <div class="add_users_lib_register"> 
       <font id="mobile_bak" color="#5F5F5F"></font> 
      </div> 
      <div class="form-text-enroll noc"> 
       <label>固定电话：</label> 
       <input name="waEnroll.phone" id="phone_check" class="form-text" onblur="checkSize(this,'phone',50,'该项目长度应在50字以内','')" placeholder="如+86-24-12345678" /> 
       <i class="icon icon-clear"></i> 
      </div> 
      <div class="add_users_lib_register"> 
       <font id="phone" color="#5F5F5F"></font> 
      </div> 
      <div class="form-text-enroll noc"> 
       <label>电子邮件：</label> 
       <input name="waEnroll.email" id="email_check" class="form-text" onblur="checkIsEmail(this,'email','电子邮件格式不正确','',50,'该项目长度应在50字以内')" placeholder="请输入正确的电子邮件" /> 
       <i class="icon icon-clear"></i> 
      </div> 
      <div class="add_users_lib_register"> 
       <font id="email" color="#5F5F5F"></font> 
      </div> 
      <div class="form-text-enroll noc"> 
       <label>QQ号：</label> 
       <input name="waEnroll.qqNum" id="qq_num_check" class="form-text" onblur="checkSize(this,'qq_num',50,'该项目长度应在50字以内','')" placeholder="请输入正确的QQ号" /> 
       <i class="icon icon-clear"></i> 
      </div> 
      <div class="add_users_lib_register"> 
       <font id="qq_num" color="#5F5F5F"></font> 
      </div> 
      <div class="form-text-enroll noc"> 
       <label>补充说明：</label> 
       <input name="waEnroll.description" id="description_check" class="form-text" onblur="checkSize(this,'description_t',500,'该项目长度应在500字以内','')" placeholder="长度在500字以内" /> 
       <i class="icon icon-clear"></i> 
      </div> 
      <div class="add_users_lib_register"> 
       <font id="description_t" color="#5F5F5F"></font> 
      </div> 
     </div> 
     <div class="fn-mt-login fn-mlr"> 
      <input type="button" class="m-user-submit-btn" value="报名" onclick="submitForm();" /> 
     </div> 
    </div> 
   </div> 
  </form> 
  <script>
backUrl = '';
var txtphone='';
txtpwd = '';
txtpwdMd = '';
txtseriesId = '';
txtuserName = '';
txtbackUrl = '';
</script> 
  <script type="text/javascript" src="../js/AutoHomeReg_M_min.js" ></script>
  <script type="text/javascript" src="../js/default1.5.js" ></script>
  <script type="text/javascript" src="../js/md5.js" ></script>
  <!--<script type="text/javascript" src="../js/layer.min.js" ></script>-->
  <script>
RegisterPage.Init();
</script> 
  <!--页脚--> 
  <footer class="footer"> 
   <p> <a href="../about/introduction/index.html" target="_blank">公司简介</a> | <a href="../about/connection/index.html" target="_blank">联系我们</a> </p> 
   <p>Copyright &copy; 2002-2015 All Rights Reserved</p> 
   <p> <script type="text/javascript">var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_stat_icon_1253465737'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s6.cnzz.com/z_stat.php%3Fid%3D1253465737%26show%3Dpic1' type='text/javascript'%3E%3C/script%3E"));</script> 
  <script type="text/javascript"> var _bdhmProtocol = (("https:" == document.location.protocol) ? " https://" : " http://"); document.write(unescape("%3Cscript src='" + _bdhmProtocol + "hm.baidu.com/h.js%3Fb3c4f201b99620c7c2a91a77921bf682' type='text/javascript'%3E%3C/script%3E")) </script> </p> 
  </footer> 
  <div class="bottom-hold"> 
   <div class="daoyou-bottom"> 
    <div style="float:left;"> 
     <p style="padding-top:15px;padding-left:10px;"> 客服热线: <a class="tel-report" name="tel-report" href="#"></a> </p> 
    </div> 
    <div style="float:right;"> 
     <a class="tel-report" name="tel-report" href="#"> <img class="daoyou-phone" src="../img/phone2.png" /> </a> 
     <a id="qqNum-report" target="_blank" href="#"> <img class="daoyou-phone" src="../img/qq.png" /> </a> 
    </div> 
   </div> 
  </div>   
 </body>
</html>